n = int(input("请输入评委个数："))
scores = []
for i in range(n):
    score = int(input("请输入第{}个评委的分数：".format(i+1)))
    scores.append(score)

max_score = max(scores)
min_score = min(scores)
scores.remove(max_score)
scores.remove(min_score)
avg_score = sum(scores)/len(scores)
print("去掉一个最高分{0}，去掉一个最低分{1}，最终得分为{2:.2f}".format(max_score, min_score, avg_score))